package demo1;

import java.util.Objects;

public class Person {


    public String id;

    @Override
    public String toString() {
        return "Person{" +
                "id=" + id +
                '}';
    }

    public Person(String id) {
        this.id = id;
    }

    @Override
    public boolean equals(Object o) {
        Person p=(Person)o;
        return this.getClass()==p.getClass();

    }

    @Override
    public int hashCode() {
        return Objects.hash();
    }
}


//if (this == o) return true;
//        if (o == null || getClass() != o.getClass()) return false;
//        Person person = (Person) o;
//        return Objects.equals(id, person.id);